package com.oscar.practice.pattern.observer;

import java.util.Observer;

/**
 * 客户端
 *
 * @author tongyufu
 * @since 2019年6月11日 下午10:52:41
 */
public class Client {

    public static void main(String[] args) {
        Observer manager = new Manager();
        Observer boss = new Boss();
        Worker worker = new Worker();

        worker.addObserver(manager);
        worker.addObserver(boss);

        worker.breakfast();
        worker.work();
    }

}
